home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 14 / CU Amiga Magazine's Super CD-ROM 14 (1997)(EMAP Images)(GB)(Track 1 of 3)[!][issue 1997-09].iso / CUCD / Programming / AMOS / AMOSList0597 / AMOSLIST / text0273.txt < prev    next >
Encoding:
Text File  |  1997-06-01  |  2.1 KB  |  52 lines

  1. On 23-May-97, Joona I Palaste wrote:
  2. >On Fri, 23 May 1997, James Brown wrote:
  3.  
  4. >> The subject said it all...
  5. >> Is there a way to do Isometric Maps in amos??
  6. >> 
  7. >> Thanks in advance,
  8. >>                    Amigo
  9.  
  10. >There isn't one as a standard, but it can be created with a little
  11. >programming ingenuity (sp?). One method, which I intend to use someday,
  12.  
  13. It can certainly be done! It is VERY easy to set up a routine to redraw the
  14. entire screen, but if you want to update only parts it gets a little tougher.
  15. My map editor allows the creation of isometric maps, and as with all other
  16. types of map, it includes the facility to write the sourcecode to display it. 
  17. Anyway, to draw an entire screenful of isometric tiles:
  18.  
  19. 1. Draw them in a paint package or whatever.
  20. 2. Cut them out as icons (make sure your background colour is 0)
  21. 3. Use the `Set Icon Mask' command from AMOS (Use a loop to mask all the
  22. tiles)
  23. 4. Set up a for next loop, to decrement half of Y for each X.
  24. E.G: This routine draws a 10x10 map on the screen (using a highly inefficient
  25. array, but you get the picture)
  26.  
  27. For Y=0 To 9
  28.    For X=0 To 9
  29.       Paste Icon X*8-(Y mod 2)*8,Y*8+X*8,Tile(X,Y)
  30.    Next X
  31. Next Y
  32.  
  33. Don't have the source to hand, but I'm pretty sure that is the basic way to do
  34. it.
  35.  
  36. To update just a bit of the screen requires another screen and nine draw
  37. operations (or alpha-channel masking, which AMOS doesn't have). It is too
  38. complex to explain here.
  39.  
  40. -- 
  41. &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
  42. & ####  ##  #     ##   ##  #  #                                        &
  43. & #    #  # #    #  # #  # ## #    -=   S  O  F  T  W  A  R  E  =-     &
  44. & #### #### #    #    #  # ## #                                        &
  45. & #    #  # #    #  # #  # # ##          falcons@ihug.co.nz            &
  46. & #    #  # ####  ##   ##  #  #                                        &
  47. &                                                                      &
  48. & Laurie Curwood    http://www.geocities.com/siliconvalley/lakes/6291/ &
  49. &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
  50.  
  51.  
  52.